package com.ec.common.constant;

public class SysConstant {
    // 限制字符串包含数字、字母以及指定的特殊字符，长度在 8 到 16 个字符之间  (以下为密码、邮箱限制）
    public static final String REGEX_PASSWORD = "^(?=.*\\d)(?=.*[a-zA-Z])[a-zA-Z0-9~!@#$%^&*_]{8,16}$";
    public static final String REGEX_EMAIL = "^[a-zA-Z0-9_+&*-]+(?:\\.[a-zA-Z0-9_+&*-]+)*@(?:[a-zA-Z0-9-]+\\.)+[a-zA-Z]{2,7}$";


    // token的存活时间（1天）
    public static final Integer KEY_SURVIVAL_ONE_DAY = 60 * 1000 * 60 * 24;

    // token缓存在Redis的key前缀
    public static final String REDIS_KEY_TOKEN =  "token:";

    public final static String CAPTCHA_KEY = "captcha";
    public final static String AUTHORITY_KEY = "authority";
    public final static String DEFAULT_PASSWORD="123456";

}
